home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 5031 < prev    next >
Encoding:
Text File  |  1996-08-06  |  630 b   |  24 lines

  1. Newsgroups: comp.lang.c++
  2. Path: in2.uu.net!allegra!alice!ark
  3. From: ark@research.att.com (Andrew Koenig)
  4. Subject: Re: Is it possible to use templates with structures?
  5. Message-ID: <DM494E.MB9@research.att.com>
  6. Organization: AT&T Research, Murray Hill NJ
  7. References: <4eq9s5$l14@nntp.hut.fi>
  8. Distribution: inet
  9. Date: Thu, 1 Feb 1996 21:31:25 GMT
  10.  
  11. In article <4eq9s5$l14@nntp.hut.fi> casper@lk-hp-10.hut.fi (Casper Gripenberg) writes:
  12.  
  13. > Can I do:
  14.  
  15. > template<class T>
  16. > struct Foo {
  17. >   T *data;
  18. > };
  19.  
  20. Sure -- the only difference between struct and class is the default visibility.
  21. -- 
  22.                 --Andrew Koenig
  23.                   ark@research.att.com
  24.